package org.govhack.okcapital.model;

public class DatasetWithData {
    public Dataset dataset;
    public double[] data;
    public double multiplier;
    
    public DatasetWithData(Dataset dataset, double[] data, double multiplier) {
        super();
        this.dataset = dataset;
        this.data = data;
        this.multiplier = multiplier;
    }
    
    
    public double getMax() {
        double max = Double.MIN_VALUE;
        
        for (int i = 0; i < data.length; i++) {
            if (max < data[i]) {
                max = data[i];
            }
        }
        
        return max;
    }
    
    public double getMin() {
        double min = Double.MAX_VALUE;
        
        for (int i = 0; i < data.length; i++) {
            if (min > data[i]) {
                min = data[i];
            }
        }
        
        return min;
    }
}
